package com.zhang.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;

@Api(tags = "客户实体类")
@Data
@NoArgsConstructor
@TableName("t_custom")
public class CustomBean implements Serializable {

    @ApiModelProperty("客户id")
    @TableId(value = "pk_customId",type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty("客户名")
    @TableField(value = "c_name")
    private String name;

    @ApiModelProperty("客户负责人")
    @TableField(value = "c_person")
    private String person;

    @ApiModelProperty("负责人电话")
    @TableField(value = "c_phone")
    private String phone;

    @ApiModelProperty("客户地址")
    @TableField(value = "c_address")
    private String address;

    @ApiModelProperty("邮箱")
    @TableField(value = "c_email")
    private String email;

    @ApiModelProperty("客户经营范围")
    @TableField(value = "c_scope")
    private String scope;

    public CustomBean(String name, String person, String phone, String address, String email, String scope) {
        this.name = name;
        this.person = person;
        this.phone = phone;
        this.address = address;
        this.email = email;
        this.scope = scope;
    }

    @Override
    public String toString() {
        return "CustomBean{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", person='" + person + '\'' +
                ", phone='" + phone + '\'' +
                ", address='" + address + '\'' +
                ", email='" + email + '\'' +
                ", scope='" + scope + '\'' +
                '}' + "\n";
    }
}
